package org.genntii.smdomain.entity;

import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.*;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.time.LocalDateTime;

@Data
@Builder
@TableName("Article")
@NoArgsConstructor
@AllArgsConstructor
public class Article {
    @TableId(type = IdType.AUTO)
    private Long id;
    private Long userId;
    private Long channelId;
    private String title;
    @TableField(exist = false)
    private String content;
    private Integer like;
    private Integer dislike;
    private Integer cityCode;
    private String city;
    private byte status;
    @TableField(fill = FieldFill.INSERT)
    private LocalDateTime createTime;
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private LocalDateTime updateTime;
    private Integer view;
    @TableField(exist = false)
    private Integer userArticleCount;
    private Integer userFollowerCount;
}
